package com.tzm.gaflow.web.vo;

import cn.hutool.core.bean.BeanUtil;
import cn.hutool.json.JSONUtil;

import java.io.Serializable;

/**
 * BaseVO
 *
 */
public abstract class BaseVO<T> implements Serializable {

	private static final long serialVersionUID = 1;

	public T copyFrom(Object from) {
		BeanUtil.copyProperties(from,this);
		return (T) this;
	}

	public String toJson() {
		return JSONUtil.toJsonStr(this);
	}
}
